package org.solrcn.segment;

import java.util.HashMap;
import java.util.List;
import java.util.Map;

public class DataModel {

	// 词频
	Map<String, Long> termFreq = new HashMap<String, Long>();

	// 词前缀
	Map<String, List<String>> termPrefix;
	// 词后缀
	Map<String, List<String>> termSuffix;

	//
	List<String>[] startOffsetIndex;
	List<String>[] endOffsetIndex;
	
	public void addTerm(String term) {
		if (termFreq.get(term) == null) {
			termFreq.put(term, 1L);
		} else {
			termFreq.put(term, termFreq.get(term) + 1);
		}
	}
}
